#ifndef __MYHEAD_H__
#define __MYHEAD_H__

#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <pthread.h>
#include <sqlite3.h>
#include <sys/types.h>          /* See NOTES */
#include <sys/socket.h>
#include <arpa/inet.h>
#include <netinet/in.h>
#include <netinet/ip.h> /* superset of previous */
#include <unistd.h>
#include <errno.h>
#include <sys/epoll.h>

#define ERR_LOG(msg) do{                                                \
        printf("%s,%s,%d\n\t", __FILE__, __func__, __LINE__);           \
        perror(msg);                                                    \
        return -1;                                                      \
    } while (0)                                                        

#define ERR_PRIENT(msg) do{                                             \
        printf("%s,%s,%d\n\t", __FILE__, __func__, __LINE__);           \
        perror(msg);                                                    \
        printf("\n");                                                   \
    } while (0)      

#define INFO_LOG(fmt, args...) do{                                      \
        printf("%s,%s,%d: \n\t", __FILE__, __func__, __LINE__);         \
        printf(fmt, ##args);                                            \
        printf("\n");                                                   \
    } while (0)      

#endif